from django.db import models


class AddRoleForm(models.Model):
    PID = models.CharField()
    role_name = models.CharField()
    role_desc = models.CharField()
    role_func = models.CharField(help_text="接收Function ID，中间以英文逗号分隔")


class AddFunctionForm(models.Model):
    PID = models.CharField()
    function = models.CharField(help_text=
                                "[{‘func_name’:‘功能’,‘desc’:‘描述’,‘type’:‘分類名’},...],請使用英文符號")


class AddUserRoleForm(models.Model):
    username = models.CharField()
    role = models.CharField(help_text="请输入列表类型的Role ID,格式如：[1,2,3,4,...]。添加个数不限，但必须是[]类型")


class RoleFunctionForm(models.Model):
    role = models.CharField(max_length=100)
    function = models.CharField(max_length=100)
    # function_list = models.CharField(max_length=100)


class PublicForm(models.Model):
    pass

